package com.zhijian.medical.service;

import com.zhijian.medical.entity.po.UserKeepTime;
import com.zhijian.medical.entity.vo.request.UserKeepTimeSaveOrUpdateVo;
import com.zhijian.medical.entity.vo.request.UserKeepTimeSearchVo;
import com.zhijian.medical.entity.vo.response.UserKeepTimeVo;
import com.zhijian.util.page.Page;

import java.util.List;

/**
 * 学习计时表 业务处理层
 *
 * @author auto
 * @version 1.0
 * @date 2024-04-13 13:32:57
 */
public interface UserKeepTimeService {

    /**
     * 主键查询
     *
     * @param id
     * @return
     */
    UserKeepTime selectById(Long id);

    /**
     * 主键查询vo
     *
     * @param id
     * @return
     */
    UserKeepTimeVo selectVoById(Long id);

    /**
     * 按照主键删除
     *
     * @param id
     */
    void deleteById(Long id);

    /**
     * 按照主键批量删除
     *
     * @param idList
     */
    void deleteByIdList(List<Long> idList);

    /**
     * 新增
     *
     * @param userKeepTime
     * @return
     */
    Long insert(UserKeepTime userKeepTime);

    /**
     * 更改
     *
     * @param userKeepTime
     * @return
     */
    boolean update(UserKeepTime userKeepTime);

    /**
     * 动态修改
     *
     * @param record
     * @return
     */
    boolean updateByPrimaryKeySelective(UserKeepTime record);

    /**
     * 保存
     *
     * @param saveOrUpdateVo
     * @return
     */
    boolean save(UserKeepTimeSaveOrUpdateVo saveOrUpdateVo);

    /**
     * 编辑
     *
     * @param saveOrUpdateVo
     * @return
     */
    boolean modify(UserKeepTimeSaveOrUpdateVo saveOrUpdateVo);

    /**
     * 列表
     *
     * @param userKeepTimeSearchVo
     * @return
     */
    UserKeepTimeVo selectOne(UserKeepTimeSearchVo userKeepTimeSearchVo);

    /**
     * 总数
     *
     * @param userKeepTimeSearchVo
     * @return
     */
    Integer count(UserKeepTimeSearchVo userKeepTimeSearchVo);

    /**
     * 列表
     *
     * @param userKeepTimeSearchVo
     * @return
     */
    List<UserKeepTimeVo> selectList(UserKeepTimeSearchVo userKeepTimeSearchVo);

    /**
     * 分页查询
     *
     * @param userKeepTimeSearchVo
     * @return
     */
    Page<UserKeepTimeVo> selectPage(UserKeepTimeSearchVo userKeepTimeSearchVo);

    /**
     * 批量新增数据（MyBatis原生foreach方法）
     *
     * @param entities 实例对象列表
     * @return 影响行数
     */
    boolean insertBatch(List<UserKeepTime> entities);

    /**
     * 动态删除，慎重用此方法！！
     *
     * @param userKeepTimeSearchVo
     * @return
     */
    void deleteByCondition(UserKeepTimeSearchVo userKeepTimeSearchVo);
}